package com.eblacorp.archive.service;

import java.beans.IntrospectionException;
import java.io.File;
import java.io.IOException;
import java.lang.reflect.InvocationTargetException;
import java.util.List;

import com.eblacorp.archive.domain.fn.DrawingDocument;
import com.eblacorp.archive.exceptions.NoAttachedFnDocument;
import com.eblacorp.archive.exceptions.NotFnDocumentException;
import com.eblacorp.archive.exceptions.NullValueException;

public interface DrawingDocumentService {
	public List<DrawingDocument> search(DrawingDocument drawingDocument,Integer startPage, Integer pageSize, boolean withDocument)throws IllegalArgumentException, NotFnDocumentException, IntrospectionException, IllegalAccessException, InvocationTargetException, InstantiationException ;
	public DrawingDocument addNewDocument(DrawingDocument drawingDocument, File file) throws IllegalArgumentException, NotFnDocumentException, IntrospectionException, IllegalAccessException, InvocationTargetException, InstantiationException, NullValueException, IOException;
	public void deleteDocument(DrawingDocument drawingDocument, boolean allVersion) throws IllegalArgumentException, IntrospectionException, IllegalAccessException, InvocationTargetException, NullValueException ;
	DrawingDocument updateDocument(DrawingDocument drawingDocument, File file)throws IllegalArgumentException, IntrospectionException,IllegalAccessException, InvocationTargetException,NullValueException, IOException;
	String getViewerUrl(DrawingDocument drawingDocument);
	byte[] download(DrawingDocument drawingDocument)throws NoAttachedFnDocument, IOException;
}
